home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2007 September / PCWSEP07.iso / Software / Linux / Linux Mint 3.0 Light / LinuxMint-3.0-Light.iso / casper / filesystem.squashfs / usr / bin / ucfq < prev    next >
Encoding:
Text File  |  2006-11-16  |  18.6 KB  |  846 lines

  1. #!/usr/bin/perl
  2. #                              -*- Mode: Cperl -*- 
  3. # ucfq --- 
  4. # Author           : Manoj Srivastava ( srivasta@glaurung.internal.golden-gryphon.com ) 
  5. # Created On       : Wed Apr 12 14:51:16 2006
  6. # Created On Node  : glaurung.internal.golden-gryphon.com
  7. # Last Modified By : Manoj Srivastava
  8. # Last Modified On : Fri Apr 14 19:30:45 2006
  9. # Last Machine Used: glaurung.internal.golden-gryphon.com
  10. # Update Count     : 81
  11. # Status           : Unknown, Use with caution!
  12. # HISTORY          : 
  13. # Description      : 
  14. # arch-tag: 1390e09f-ee31-4d7f-a968-bd539ea061a0
  15. #
  16. =head1 NAME
  17.  
  18. ucfq - query ucf registry and hashfile about configuration file details.
  19.  
  20. =cut
  21.  
  22. use strict;
  23.  
  24.  
  25. package ucf;
  26.  
  27. use strict;
  28. use Getopt::Long;
  29.  
  30. # set the version and revision
  31. ($main::MYNAME     = $main::0) =~ s|.*/||;
  32. $main::Author      = "Manoj Srivastava";
  33. $main::AuthorMail  = "srivasta\@debian.org";
  34.  
  35. =head1 SYNOPSIS
  36.  
  37.  usage: ucfq [options] (file|package)[file|package  ...]
  38.  
  39. =cut
  40.  
  41.  
  42. {  # scope for ultra-private meta-object for class attributes
  43.  
  44.   my %Ucf = 
  45.     (
  46.      Optdesc  => 
  47.      {
  48.       'help|h'         => sub {print ucf->Usage();     exit 0;},
  49.       'with-colons|w!' => sub {$::ConfOpts{"Colons"}= "$_[1]";},
  50.       'state-dir=s'    => sub {$::ConfOpts{"StateDir"}= "$_[1]";},
  51.       'debug|d'        => sub {$::ConfOpts{"DEBUG"}+= "$_[1]";},
  52.       'verbose|v'      => sub {$::ConfOpts{"VERBOSE"}+= "$_[1]";}
  53.      },
  54.      Usage => qq(Usage: $main::MYNAME [options]
  55. Author: $main::Author <$main::AuthorMail>
  56.   where options are:
  57.  --help                This message.
  58.  --debug               Turn on debugging mode.
  59.  --verbose             Make the script more verbose.
  60.  --with-colons         A compact, machine readable version of the output.
  61.  --state-dir </path/>  Set the state directory to /path/ instead of the
  62.                        default /var/lib/ucf.
  63.  
  64. ),
  65.      Defaults => 
  66.      {
  67.       "Colons"   => 0,
  68.       "DEBUG"    => 0,
  69.       "VERBOSE"  => 0,
  70.       "StateDir" => '/var/lib/ucf'
  71.      }
  72.     );
  73.   # tri-natured: function, class method, or object method
  74.   sub _classobj {
  75.     my $obclass = shift || __PACKAGE__;
  76.     my $class   = ref($obclass) || $obclass;
  77.     no strict "refs";   # to convert sym ref to real one
  78.     return \%$class;
  79.   }
  80.  
  81.   for my $datum (keys %Ucf ) {
  82.     no strict "refs";
  83.     *$datum = sub {
  84.       use strict "refs";
  85.       my ($self, $newvalue) = @_;
  86.       $Ucf{$datum} = $newvalue if @_ > 1;
  87.       return $Ucf{$datum};
  88.     }
  89.   }
  90. }
  91.  
  92. =head1 OPTIONS
  93.  
  94. =over 3
  95.  
  96. =item B<--help> B<h> Print out a usage message.
  97.  
  98. =item B<--debug> B<-d> Turn on debugging mode.
  99.  
  100. =item B<--verbose> B<-v> Make the script more verbose..
  101.  
  102. =item B<--with-colons> B<-w>
  103.  
  104. =over 2
  105.  
  106. Normally, the script presents the information in a human readable
  107. tabular format, but that may be harder for a machine to parse. With
  108. this option, the output is a compact, colon separated line, with no
  109. dividers, headers, or footer.
  110.  
  111. =back
  112.  
  113. =item B<--state-dr> dir
  114.  
  115. =over 2
  116.  
  117. Set the state directory to C</path/to/dir> instead of the default
  118. C</var/lib/ucf>.  Used mostly for testing.
  119.  
  120. =back
  121.  
  122. =back
  123.  
  124. =cut
  125.  
  126.  
  127. =head1 DESCRIPTION
  128.  
  129.  
  130. This script takes a set of arguments, each of which is a package or a
  131. path to a configuration file, and outputs the associated package, if
  132. any, if the file exists on disk, and whether it has been modfied by te
  133. user.  The output is either a human readable tabular form, or a
  134. compact colon-separated machine friendly format.
  135.  
  136. This script can potentially be used in package C<postinst> scripts
  137. during purge to query the system for configuration files that may
  138. still exist on the system, and whether these files have been locally
  139. modified by the user -- assuming that the package registered all the
  140. configuration files with B<ucf> using C<ucfr>.
  141.  
  142. =cut
  143.  
  144.  
  145.  
  146.  
  147. =head1 INTERNALS
  148.  
  149. =head2 Class Methods
  150.  
  151. All class methods mediate access to class variables.  All class
  152. methods can be invoked with zero or one parameters. When invoked with
  153. the optional parameter, the class method sets the value of the
  154. underlying class data.  In either case, the value of the underlying
  155. variable is returned.
  156.  
  157. =cut
  158.  
  159. =head1 Class ucf
  160.  
  161. This is a combination view and controller class that mediates between
  162. the user and the internal model classes.
  163.  
  164.  
  165. =head2 new
  166.  
  167. This is the constructor for the class. It takes a number of optional
  168. parameters. If the parameter B<Colons> is present, then the output
  169. will be compact. The parameters B<DEBUG> and B<VERBOSE> turn on
  170. additional diagnostics from the script.
  171.  
  172. =cut
  173.  
  174. sub new {
  175.   my $this = shift;
  176.   my %params = @_;
  177.   my $class = ref($this) || $this;
  178.   my $self = {};
  179.  
  180.   bless $self => $class;
  181.  
  182.   # validate and sanitize the settings
  183.   $self->validate(%params);
  184.   
  185.   return $self;
  186. }
  187.  
  188. =head2 validate
  189.  
  190. This routine is responsible for ensuring that the parameters passed in
  191. (presumably from the command line) are given preference. 
  192.  
  193. =cut
  194.  
  195. sub validate{
  196.   my $this     = shift;
  197.   my %params   = @_;
  198.   my $defaults = $this->Defaults();
  199.  
  200.  
  201.   # Make sure runtime options override what we get from the config file
  202.   for my $option (keys %params) {
  203.     $this->{Con_Ref}->{"$option"} = $params{"$option"};
  204.   }
  205.  
  206.   # Ensure that if default parameters have not been set on the comman
  207.   # line on in the configuration file, if any, we use the built in
  208.   # defaults.
  209.   for my $default (keys %$defaults) {
  210.     if (! defined $this->{Con_Ref}->{"$default"}) {
  211.       $this->{Con_Ref}->{"$default"} = $defaults->{"$default"};
  212.     }
  213.   }
  214. }
  215.  
  216. =head2 get_config_ref
  217.  
  218. This routine returns a reference to the configuration hash
  219.  
  220. =cut
  221.  
  222. sub get_config_ref {
  223.  
  224.   my $this     = shift;
  225.   return $this->{Con_Ref};
  226. }
  227.  
  228. =head2 dump_config 
  229.  
  230. This routine returns a C<Data::Dumper> for debugging purposes
  231.  
  232. =cut
  233.  
  234. sub dump_config {
  235.   my $this     = shift;
  236.   for (keys %{$this->{Con_Ref}}) {
  237.     print  "$_ = [${$this->{Con_Ref}}{$_}]\n"
  238.   }
  239. }
  240.  
  241. =head2 process
  242.  
  243. This routine is the work horse routine -- it parses the command line
  244. arguments, and queries the on disk databases, determines of the files
  245. exist, and have been modified.
  246.  
  247. =cut
  248.  
  249.  
  250. sub process {
  251.   my $this      = shift;
  252.  
  253. # Step 1: Process all arguments in sequence.
  254. # Step 2: determine if the arument given is a package name (no / in
  255. #         arg)
  256.  
  257.   %{$this->{packages}}    = map { +"$_" => 1} grep {! m,/,} @ARGV;
  258.   %{$this->{configs}}     = map { +"$_" => 1} grep {  m,/,} @ARGV;
  259.   $this->{pkg_list}       = object_list->new;
  260.   $this->{file_list}      = object_list->new;
  261.   $this->{registry_proxy} = 
  262.     registry->new("StateDir" => $this->{Con_Ref}->{StateDir});
  263.   $this->{hashfile_proxy} = 
  264.     hashfile->new("StateDir" => $this->{Con_Ref}->{StateDir});
  265.  
  266.   for (keys %{$this->{packages}} ) {
  267.     my $package = pkg->new('Name' => "$_");
  268.     $this->{pkg_list}->element($_, $package);
  269.   }
  270.   for (keys %{$this->{configs}}) {
  271.     my $file = conffile->new('Name' => "$_");
  272.     $this->{file_list}->element($_, $file);
  273.   }
  274. # Step 3: If so, gather all files associated with the package
  275.   for my $package ($this->{pkg_list}->list) {
  276.     my $pkg_files = $this->{registry_proxy}->list_files($package);
  277.     for my $file (@$pkg_files) {
  278.       if (! defined $this->{file_list}->element($file)) {
  279.         my $ret = conffile->new('Name' => "$file");
  280.         $this->{file_list}->element($file, $ret);
  281.       }
  282.       $this->{file_list}->element($file)->{Package} = $package;
  283.     }
  284.   }
  285. # Step 4: for all configuration files, determine package (unless
  286. #         already determined), if any
  287. # Step 5: For each configuration file, check if it exists
  288. # Step 6: For each existing file, see if it has been changed
  289.  
  290.   for my $file ($this->{file_list}->list) {
  291.     $this->{file_list}->element($file)->{Hash} = 
  292.       $this->{hashfile_proxy}->hash($file);
  293.     if (! defined $this->{file_list}->element($file)->{Package}) {
  294.       $this->{file_list}->element($file)->{Package} = 
  295.         $this->{registry_proxy}->find_pkg($file);
  296.     }
  297.   }
  298. }
  299.  
  300. =head2 report
  301.  
  302. This routine generates a nicely formatted report based on the
  303. information gathered during the processing. There are two kinds of
  304. reports, the first being a user friendly tabular form, the second
  305. (turned on by the C<-w> option) a easily parseable colon separated
  306. report.
  307.  
  308. =cut
  309.  
  310.  
  311. our ($out_pkg, $out_file, $there, $mod);
  312.  
  313. format STDOUT_TOP =
  314. Configuration file                            Package             Exists Changed
  315. .
  316.  
  317. format STDOUT =
  318. @<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<<<< @|||   @|||
  319. $out_file,                                    $out_pkg,           $there,$mod
  320. .
  321.  
  322. sub report {
  323.   my $this      = shift;
  324.   for my $file (sort $this->{file_list}->list) {
  325.     ($out_pkg, $out_file, $there, $mod) =
  326.       $this->{file_list}->element($file)->report;
  327.     if ($this->{Con_Ref}->{Colons}) {
  328.       print "$out_file:$out_pkg:$there:$mod\n";
  329.     }
  330.     else {
  331.       write;
  332.     }
  333.   }
  334. }
  335.  
  336. =head1 Class registry
  337.  
  338. This moel class encapsulates the package-configuration file
  339. associations registry.  It parses the data in the registry, and
  340. provides methods to query the registry based either on package name,
  341. or the full path of the configuration file.
  342.  
  343. =cut
  344.  
  345. package registry;
  346. use strict;
  347.  
  348. =head2 new
  349.  
  350. This is the constructor for the class.  It takes a required parameter
  351. B<StateDir>, and based on that, proceeds toparse the registry and
  352. populate internal data structures.
  353.  
  354. =cut
  355.  
  356. sub new {
  357.   my $this = shift;
  358.   my %params = @_;
  359.   my $class = ref($this) || $this;
  360.   my $self = {};
  361.  
  362.   die "Missing required parameter StateDir"
  363.     unless $params{StateDir};
  364.  
  365.   if (-e "$params{StateDir}/registry") {
  366.     if (! -r "$params{StateDir}/registry") {
  367.       die "Can't read registry file $params{StateDir}/registry:$!";
  368.     }
  369.     open (REG, "$params{StateDir}/registry") || 
  370.       die "Can't read registry file $params{StateDir}/registry:$!";
  371.     while (<REG>) {
  372.       chomp;
  373.       my ($pkg, $file) = m/^(\S+)\s+(\S+)$/;
  374.       $self->{Packages}->{$file} = $pkg;
  375.       if (exists $self->{List}->{$pkg}) {
  376.         push @{$self->{List}->{$pkg}}, $file;
  377.       }
  378.       else {
  379.         $self->{List}->{$pkg} = [ $file ];
  380.       }
  381.     }
  382.   }
  383.  
  384.   bless $self => $class;
  385.  
  386.   return $self;
  387. }
  388.  
  389. =head2 list_files
  390.  
  391. This routine queries the registry and lists all configuration files
  392. associated with the given package.  Takes the package name as a
  393. required parameter.
  394.  
  395. =cut
  396.  
  397. sub list_files {
  398.   my $this      = shift;
  399.   my $pkg       = shift;
  400.  
  401.   if (exists $this->{List}->{$pkg}) {
  402.     return [ @{$this->{List}->{$pkg}} ];
  403.   }
  404.   else {
  405.     return [];
  406.   }
  407. }
  408.  
  409.  
  410. =head2 list_files
  411.  
  412. This routine queries the registry for the package associated with the
  413. given file.  Takes the path of the configuration file as a required
  414. parameter.
  415.  
  416. =cut
  417.  
  418. sub find_pkg {
  419.   my $this      = shift;
  420.   my $file      = shift;
  421.  
  422.   if (exists $this->{Packages}->{$file}) {
  423.     return $this->{Packages}->{$file};
  424.   }
  425.   else {
  426.     return undef;
  427.   }
  428. }
  429.  
  430. =head1 Class hashfile
  431.  
  432. This moel class encapsulates the configuration file hash database.  It
  433. parses the data in the database, and provides methods to query the
  434. hash of the configuration file.
  435.  
  436. =cut
  437.  
  438. package hashfile;
  439. use strict;
  440.  
  441. sub new {
  442.   my $this = shift;
  443.   my %params = @_;
  444.   my $class = ref($this) || $this;
  445.   my $self = {};
  446.  
  447.   die "Missing required parameter StateDir"
  448.     unless $params{StateDir};
  449.  
  450.  
  451.   if (-e "$params{StateDir}/hashfile") {
  452.     if (! -r "$params{StateDir}/hashfile") {
  453.       die "Can't read registry file $params{StateDir}/hashfile:$!";
  454.     }
  455.     open (HASH, "$params{StateDir}/hashfile") || 
  456.       die "Can't read registry file $params{StateDir}/hashfile:$!";
  457.     while (<HASH>) {
  458.       chomp;
  459.       my ($hash, $file) = m/^(\S+)\s+(\S+)$/;
  460.       $self->{$file} = $hash
  461.     }
  462.   }
  463.  
  464.   bless $self => $class;
  465.  
  466.   return $self;
  467. }
  468.  
  469.  
  470. =head2 list_files
  471.  
  472. This routine queries the database for the hash associated with the
  473. developers version of the given file.  Takes the path of the
  474. configuration file as a required parameter.
  475.  
  476. =cut
  477.  
  478.  
  479. sub hash {
  480.   my $this      = shift;
  481.   my $file      = shift;
  482.   my $value     = shift;
  483.  
  484.   if ($value) {
  485.     $this->{$file} = $value;
  486.   }
  487.   return $this->{$file};
  488. }
  489.  
  490. =head1 class conffile
  491.  
  492. This is the encapsulation of a configuration file metadata.
  493.  
  494. =cut
  495.  
  496.  
  497.  
  498. package conffile;
  499. use strict;
  500.  
  501.  
  502. =head2 new
  503.  
  504. This is the constructor for the class. It takes a number of optional
  505. parameters. If the parameter B<Colons> is present, then the output
  506. will be compact. The parameters B<DEBUG> and B<VERBOSE> turn on
  507. additional diagnostics from the script.
  508.  
  509. =cut
  510.  
  511. sub new {
  512.   my $this = shift;
  513.   my %params = @_;
  514.   my $class = ref($this) || $this;
  515.   my $self = {};
  516.  
  517.   die "Missing required parameter Name"
  518.     unless $params{Name};
  519.   $self->{Name}    = $params{Name};
  520.   $self->{Package} = $params{Package}
  521.     if $params{Package};
  522.   $self->{Exists}  = 'Yes' if -e $self->{Name};
  523.  
  524.   bless $self => $class;
  525.  
  526.   return $self;
  527. }
  528.  
  529.  
  530. =head2 package
  531.  
  532. This routine is the accessor method of the internal attribute that
  533. holds package name associated with the file.  If an optional C<value>
  534. is present, updates the value of the attribute.
  535.  
  536. =cut
  537.  
  538. sub package {
  539.   my $this      = shift;
  540.   my $name      = shift;
  541.   my $value     = shift;
  542.  
  543.   die "Missing required parameter Name"
  544.     unless $name;
  545.   if ($value ) {
  546.     $this->{Package} = $value;
  547.   }
  548.   if (exists $this->{Package}) {
  549.     return $this->{Package};
  550.   }
  551.   else {
  552.     return undef;
  553.   }
  554. }
  555.  
  556. =head2 file_exists
  557.  
  558. This routine is the accessor method of the internal attribute that
  559. holds the information whether the file exists on disk or not.
  560.  
  561. =cut
  562.  
  563. sub file_exists {
  564.   my $this      = shift;
  565.   my $name      = shift;
  566.   my $value     = shift;
  567.  
  568.   die "Missing required parameter Name"
  569.     unless $name;
  570.   if (exists $this->{Exists}) {
  571.     return $this->{Exists};
  572.   }
  573.   else {
  574.     return undef;
  575.   }
  576. }
  577.  
  578. =head2 modified
  579.  
  580. This routine is the accessor method of the internal attribute that
  581. holds the information whether the file exists on disk or not.  If an
  582. optional C<value> is present, updates the value of the attribute.
  583.  
  584. =cut
  585.  
  586. sub modified {
  587.   my $this      = shift;
  588.   my $name      = shift;
  589.   my $value     = shift;
  590.  
  591.   die "Missing required parameter Name"
  592.     unless $name;
  593.   if ($value ) {
  594.     $this->{Modified} = $value;
  595.   }
  596.   if (exists $this->{Modified}) {
  597.     return $this->{Modified};
  598.   }
  599.   else {
  600.     return undef;
  601.   }
  602. }
  603.  
  604. =head2 hash
  605.  
  606. This routine is the accessor method of the internal attribute that
  607. holds the hash for the developers version of the file.  If an optional
  608. C<value> is present, updates the value of the attribute.  It also
  609. notes whether or not the file is modified from the developers version.
  610.  
  611. =cut
  612.  
  613. sub hash {
  614.   my $this      = shift;
  615.   my $name      = shift;
  616.   my $value     = shift;
  617.  
  618.   die "Missing required parameter Name"
  619.     unless $name;
  620.   if ($value ) {
  621.     $this->{Hash} = $value;
  622.     if (-e "$name") {
  623.       if (-x "/usr/bin/md5sum") {
  624.         open (NEWHASH, "/usr/bin/md5sum $name |") || 
  625.           die "Could not run md5sum: $!";
  626.         while (<NEWHASH>) {
  627.           chomp;
  628.           my ($hash, $dummy) = m/^(\S+)\s+(\S+)$/;
  629.           if ("$hash" ne "$value") {
  630.             $this->{Modified} = 'Yes';
  631.           }
  632.         }
  633.         close NEWHASH;
  634.       }
  635.       else {
  636.         die "Could not find /usr/bin/md5sum .\n";
  637.       }
  638.     }
  639.   }
  640.   if (exists $this->{Hash}) {
  641.     return $this->{Hash};
  642.   }
  643.   else {
  644.     return undef;
  645.   }
  646. }
  647.  
  648. sub report {
  649.   my $this      = shift;
  650.   return $this->{Package} ? $this->{Package} : "",
  651.     $this->{Name}, $this->{Exists} ? $this->{Exists} : "",
  652.       $this->{Modified}? $this->{Modified} : "";
  653. }
  654.  
  655.  
  656. =head1 CLASS PKG
  657.  
  658. This is an encapsulation of package metadata.  Packages may be
  659. associated with configuration files.
  660.  
  661. =cut
  662.  
  663.  
  664. package pkg;
  665. use strict;
  666.  
  667.  
  668. =head2 new
  669.  
  670. This is the constructor for the class. It takes a number of optional
  671. parameters. If the parameter B<Colons> is present, then the output
  672. will be compact. The parameters B<DEBUG> and B<VERBOSE> turn on
  673. additional diagnostics from the script.
  674.  
  675. =cut
  676.  
  677. sub new {
  678.   my $this = shift;
  679.   my %params = @_;
  680.   my $class = ref($this) || $this;
  681.   my $self = {};
  682.  
  683.   die "Missing required parameter Name"
  684.     unless $params{Name};
  685.   $self->{Name} = $params{Name};
  686.  
  687.   bless $self => $class;
  688.  
  689.   return $self;
  690. }
  691.  
  692. sub list_files {
  693.   my $this   = shift;
  694.   return [];
  695. }
  696.  
  697. =head1 CLASS object_list
  698.  
  699. This is a clas which holds lists of object names, either packages or
  700. configuration file object names.  It provides methods to add, access,
  701. and remove objects, as well as an option to list all elements in the
  702. list.
  703.  
  704. =cut
  705.  
  706. package object_list;
  707. use strict;
  708.  
  709.  
  710.  
  711. =head2 new
  712.  
  713. This is the constructor for the class. It takes no arguments.
  714.  
  715. =cut
  716.  
  717. sub new {
  718.   my $this = shift;
  719.   my %params = @_;
  720.   my $class = ref($this) || $this;
  721.   my $self = {};
  722.  
  723.   $self->{"List"} = ();
  724.  
  725.   bless $self => $class;
  726.  
  727.   return $self;
  728. }
  729.  
  730. =head2 element
  731.  
  732. This is an accessor method for elements of the list. If an optional
  733. value argument exists, it creates or updates the element associtated
  734. with the vaslue. Takes in a required name, which is used as a kay, and
  735. an optional value argument. The value is returned.
  736.  
  737. =cut
  738.  
  739. sub element {
  740.   my $this      = shift;
  741.   my $name      = shift;
  742.   my $value     = shift;
  743.   
  744.   die "Missing required parameter Name"
  745.     unless $name;
  746.   if ($value) {
  747.     $this->{"List"}->{$name} =  $value;
  748.   }
  749.   if (exists $this->{"List"}->{$name}) {
  750.     return $this->{"List"}->{$name};
  751.   }
  752.   else {
  753.     return undef;
  754.   }
  755. }
  756.  
  757.  
  758. =head2 remove
  759.  
  760. Removes elements from the list.  Take in an required name, which is
  761. used as the key for the element to delete.
  762.  
  763. =cut
  764.  
  765. sub remove {
  766.   my $this      = shift;
  767.   my $name      = shift;
  768.   die "Missing required parameter Name"
  769.     unless $name;
  770.   delete $this->{"List"}->{$name}
  771.     if (exists $this->{"List"}->{$name} );
  772. }
  773.  
  774. =head2 list
  775.  
  776. This routine lists all the elements in the list.  It does not take any
  777. options.
  778.  
  779. =cut
  780.  
  781. sub list {
  782.   my $this      = shift;
  783.  
  784.   return keys %{$this->{"List"}};
  785. }
  786.  
  787. package main;
  788. use Getopt::Long;
  789.  
  790. sub main {
  791.   my $optdesc = ucf->Optdesc();
  792.   my $parser  = new Getopt::Long::Parser;
  793.   $parser->configure("bundling");
  794.   $parser->getoptions (%$optdesc);
  795.   my $query = ucf->new(%::ConfOpts);
  796.   $query->process;
  797.   $query->report;
  798. }
  799.  
  800. &main;
  801.  
  802. exit 0;
  803.  
  804. =head1 CAVEATS
  805.  
  806. This is very inchoate, at the moment, and needs testing.
  807.  
  808. =cut
  809.  
  810. =head1 BUGS
  811.  
  812. None Known so far.
  813.  
  814. =cut
  815.  
  816. =head1 AUTHOR
  817.  
  818. Manoj Srivastava <srivasta\@debian.org>
  819.  
  820. =head1 COPYRIGHT AND LICENSE
  821.  
  822. This script is a part of the Ucf package, and is 
  823.  
  824. Copyright (c) 2006 Manoj Srivastava <srivasta\@debian.org>
  825.  
  826. This program is free software; you can redistribute it and / or modify
  827. it under the terms of the GNU General Public License as published by
  828. the Free Software Foundation; either version 2 of the License, or
  829. (at your option) any later version.
  830.  
  831. This program is distributed in the hope that it will be useful,
  832. but WITHOUT ANY WARRANTY; without even the implied warranty of
  833. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  834. GNU General Public License for more details.
  835.  
  836. You should have received a copy of the GNU General Public License
  837. along with this program; if not, write to the Free Software
  838. Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  839.  
  840. =cut
  841.  
  842. 1;
  843.  
  844. __END__
  845.